<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>后台登陆</title>
<link href="<?=$TPL['url']?>css/login.css" rel="stylesheet" type="text/css" />
<?if(0){?>
<link href="css/login.css" rel="stylesheet" type="text/css" />
<?}?>
</head>
<script>
function Check(obj){
	var flag = true;
	if(obj.username.value == ""){
		alert("请输入你的用户名");
		obj.username.focus();
		flag = false;
	} else if(obj.password.value == ""){
		alert("请输入你的密码");
		obj.password.focus();
		flag = false;
	} else if(obj.department.value == 0){
		alert("选择你所在的部门");
		obj.department.focus();
		flag = false;
	}
	return flag;
}
</script>
<body>
  <div id="Login">
    <div id="title">
		<img src="<?=$TPL['url']?>images/login_key.gif" width="11" height="23" align="absmiddle" /> &nbsp;&nbsp;欢迎您登陆本系统	</div>
	<div id="content">
		<div id="image"><img src="<?=$TPL['url']?>images/login_img.jpg" /></div>
		<div id="form">
			<form id="form1" name="form1" method="post" action="<?=$this->url('In')?>" onsubmit="return Check(this)">
				<div id='msg'><?=$message?></div>
				<ul>
					<li>用户名：<input name="username" type="text" class=w /></li>
					<li>密&nbsp;&nbsp;&nbsp;码：<input name="password" type="password" class=w id="password" />
					  <input name="goto" type="hidden" id="goto" value="<?=$goto?>" />
					</li>
				</ul>
			  <div id="submit"><input type="submit" class="btnsubmit" value="登录" />
			    <input name="register" type="button" class="btnsubmit" value="注册" />
			  </div>
		  </form>
	  </div>
	</div>
  </div>
</body>
</html>
<script>
	document.getElementById('username').focus();
</script>